package com.zc.iotDevice.mapper;

import com.ruoyi.common.annotation.DataScope;
import com.ruoyi.common.core.domain.BaseEntity;
import com.zc.api.domain.IotDeviceAssociation;
import com.zc.iotDevice.domain.ChargeStationPile;
import com.zc.iotDevice.domain.IotDeviceSubsidiary;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface ChargeStationPileMapper {
    int deleteByPrimaryKey(String deviceId);

    int insert(ChargeStationPile record);

    int insertSelective(ChargeStationPile record);

    ChargeStationPile selectByPrimaryKey(String deviceId);

    ChargeStationPile selectStationOperatorInfo(String deviceId);

    int updateByPrimaryKeySelective(ChargeStationPile record);

    int updateByPrimaryKey(ChargeStationPile record);

    List<String> getDeviceIdList(@Param("stationCode") String stationCode);

    List<ChargeStationPile> getList(ChargeStationPile pile);

    @DataScope(deptAlias = "s")
    Map<String, Integer> getStatus(BaseEntity entity);

    int updateDelState(String id);

    /**
     * 查询站点下所有设备
     */
    List<IotDeviceAssociation> getDeviceList(IotDeviceAssociation iotDeviceAssociation);

    IotDeviceAssociation getDeviceInfo(IotDeviceAssociation iotDeviceAssociation);

    /**
     * 查询站点下设备数量
     */
    Map<String, Object> getIotDeviceNumber(@Param("stationCode") String stationCode, @Param("currentType") String currentType);

    /**
     * 查询站点下设备空闲数量
     */
    Map<String, Object> getIotDeviceNumberFree(@Param("stationCode") String stationCode,@Param("currentType") String currentType);

    /**
     * 查询充电桩当前价格策略id
     */
    Map<String, Object> getPriceTypeId(@Param("deviceId") String deviceId);
}
